package cn.wolfcode.luowowo.article.query;

import lombok.Getter;
import lombok.Setter;

import java.util.HashMap;

@Getter
@Setter
public class TravelCondition {

    public static final HashMap<Integer,TravelCondition> dayMap = new HashMap<>();
    public static final HashMap<Integer,TravelCondition> perExpendMap = new HashMap<>();
    public static final HashMap<Integer,TravelCondition> travelTimeMap = new HashMap<>();
    static {
        //出行天数
        dayMap.put(-1,null); //-1代表的是没有值
        dayMap.put(1,new TravelCondition(0,3));
        dayMap.put(2,new TravelCondition(4,7));
        dayMap.put(3,new TravelCondition(8,14));
        dayMap.put(4,new TravelCondition(15,Integer.MAX_VALUE));//最大值21亿

        //人均消费
        perExpendMap.put(-1,null); //-1代表的是没有值
        perExpendMap.put(1,new TravelCondition(1,999));
        perExpendMap.put(2,new TravelCondition(1000,6000));
        perExpendMap.put(3,new TravelCondition(6001,20000));
        perExpendMap.put(4,new TravelCondition(20001,Integer.MAX_VALUE));

        //出发天数
        travelTimeMap.put(-1,null); //-1代表的是没有值
        travelTimeMap.put(1,new TravelCondition(1,2));
        travelTimeMap.put(2,new TravelCondition(3,4));
        travelTimeMap.put(3,new TravelCondition(5,6));
        travelTimeMap.put(4,new TravelCondition(7,8));
        travelTimeMap.put(5,new TravelCondition(9,10));
        travelTimeMap.put(6,new TravelCondition(11,12));


    }



    private int min; //最小值
    private int max; //最大值
    public TravelCondition(int min, int max) {
        this.min = min;
        this.max = max;
    }
}
